[IA64] don't change NaTPAGE into WB
authorawilliam@xenbuild.aw <awilliam@xenbuild.aw>
Mon, 10 Jul 2006 20:14:11 +0000 (14:14 -0600)
committerawilliam@xenbuild.aw <awilliam@xenbuild.aw>
Mon, 10 Jul 2006 20:14:11 +0000 (14:14 -0600)
Xen/IA64 changes memory attributes of tlb into WB to prevent domU from
uncachable access.  But NaTPage attribute need not to be changed to WB.
Linux uses NaTPage attributes.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
`

xen/arch/ia64/xen/mm.c

index fc406daf2f6a7d5c321cb081e743819c834393dd..7a7f720ea47c57a2e2ad121f9df473a69f2d2f1d 100644 (file)
@@ -475,8 +475,11 @@ u64 translate_domain_pte(u64 pteval, u64 address, u64 itir__, u64* logps,
         * Don't let non-dom0 domains map uncached addresses.  This can
         * happen when domU tries to touch i/o port space.  Also prevents
         * possible address aliasing issues.
+        * WB => WB
+        * UC, UCE, WC => WB
+        * NaTPage => NaTPage
         */
-       if (d != dom0)
+       if (d != dom0 && (pteval2 & _PAGE_MA_MASK) != _PAGE_MA_NAT)
                pteval2 &= ~_PAGE_MA_MASK;
 
        return pteval2;